module.exports = {
  css: {
    sourceMap: false,
    loaderOptions: {
      scss: {
        data: '@import "~@/assets/scss/var.scss";',
        // additionalData: '@import "~@/assets/scss/element-variables.scss";',
      }
    }
  },
  devServer: {
    port: 3034,
    overlay: {
      warnings: false,
      errors: false
    },
    proxy: {
      '/api': { //此处要与 /services/api.js 中的 API_PROXY_PREFIX 值保持一致
        target: process.env.VUE_APP_API_BASE_URL,
        changeOrigin: true,
        // pathRewrite: {
        //   '^/api': ''
        // }
      }
    },
    disableHostCheck: true
  },
  lintOnSave: false,
  publicPath: process.env.VUE_APP_PUBLIC_PATH,
  outputDir: 'dist',
  assetsDir: 'static',
  productionSourceMap: false,
  configureWebpack: config => {
    config.performance = {
      hints: false
    }
  },
}
